package com.eqdd.yiqidian.ui.mine.shenqing;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.View;

import com.eqdd.yiqidian.base.BaseShowActivity;
import com.eqdd.yiqidian.base.Config;
import com.eqdd.yiqidian.ui.mine.shenqing.fragment.MyCreateNewsFragment;

public class ShowMyNewsActivity extends BaseShowActivity {
    @Override
    protected void initTitle() {
        initTopTitleBar(View.VISIBLE, "通知列表");
        initTopRightText("发布", v -> {
            startActivityForResult(CreateNewsActivity.class,null,Config.CREATE_NEWS);
        });
    }

    @Override
    public void initData() {
        titles.add("待审批");
        titles.add("已同意");
        titles.add("已拒绝");
    }

    protected Fragment getFragment(int status) {
        MyCreateNewsFragment fragment = new MyCreateNewsFragment();
        Bundle bundle = new Bundle();
        bundle.putInt(Config.STATUS, status);
        bundle.putInt(Config.WHO, 0);
        fragment.setArguments(bundle);
        return fragment;
    }

}
